﻿using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace WpfApplication1
{
    /// <summary>
    /// Interaction logic for MainWindow.xaml
    /// </summary>
    public partial class MainWindow
    {
        public Context CurrentContext { get; set; }

        public MainWindow()
        {
            InitializeComponent();
            CurrentContext = new Context();

            DataContext = CurrentContext;

            CurrentContext.ButtonName = "Button";
            CurrentContext.Title = "Text";
        }

        private void ButtonClick(object sender, RoutedEventArgs e)
        {
            CurrentContext.Title = "New Text";
            ObservableCollection<int> collection=new ObservableCollection<int>();
        }
    }
}
